package com.hollycrm.unicom.sequenceservice;

/**
 * <p>Title: </p>
 * <p>Description: </p>
 * <p>Copyright: Copyright (c) 2004</p>
 * <p>Company: </p>
 * @author not attributable
 * @version 1.0
 */

public final class SequenceManagerProxyBean implements SequenceManager {

    protected static Object synclock = new Object();

    private SequenceManager target;

    /**
     * nextSequence
     *
     * @param seqID String
     * @return String
     */
    public String nextSequence(String seqID) {
        String nextSequence = null;
        synchronized (synclock) {
            nextSequence = target.nextSequence(seqID);
        }
        return nextSequence;
    }

    public SequenceManager getTarget() {
        return target;
    }
    public void setTarget(SequenceManager target) {
        this.target = target;
    }

}
